<?php
namespace control;
/*
*绩效目标类
*/

class performanceAimClass extends adIndexClass
{
    private const page = 'performanceAim';
    private const table = 'performance_aim';
    private const title = '绩效目标';

    /*列表页-查询条件*/
    public function homeOptions($isAsync = true)
    {
        //生成查询表单
        $html = $this->tableShow([
            [
                [
                    L('performance.table.team') => select(array("name" => "team", "option" => explode('，', para('performanceTeam')))),
                    L('performance.table.aimType')     => select(array("name" => "aimType", "option" => explode('，', para('performanceAim')))),
                    L('department.table.creatTime') => text(array("name" => "createTime", 'laydate' => ['type' => 'date', 'range' => '~'])),
                ]
            ]
        ],1);
        //返回
        if(!$isAsync){
            return $html;
        }else{
            return json_encode(['html'=>$html],320);
        }
    }

    /*列表-查询条件*/
    public function home()
    {
        $html = $this->homeOptions(false);
        //控件
        $button = "";
        $url = root . "control/adIndex.html?cla=" . self::page;
        if ($this->power(self::page, "edit")) {
            $button .= "<span onclick=\"layer('".self::page."','edit')\" class='spanButton'>" . L('job.model.edit') . "</span>\n";
        }
        if ($this->power(self::page, "del")) {
            $button .= "<span class='spanButton' onclick=\"layer('{$this->get('cla')}', 'operate', {'act': 'del'})\">" . L('department.button.delete') . "</span>\n";
        }
        if ($this->power(self::page, "edit")) {
            $button .= "<span onclick=\"layer('{$this->get('cla')}','stateSwitch',{type:'启用'})\" class='spanButton'>" . L('topic.table.enable') . "</span>\n";
            $button .= "<span onclick=\"layer('{$this->get('cla')}','stateSwitch',{type:'停用'})\" class='spanButton'>" . L('topic.table.unenable') . "</span>\n";
        }
        //导入
        if ($this->power(self::page, 'import')) {
            $button .="<span class='spanButton' onclick=\"layer('importTemplate','importFrame',{cla:'".self::page."'})\">导入</span>";
        }
        if ($this->power(self::page, "export")) {
            $button .="<span class='spanButton' onclick=\"layer('importTemplate','exportFrame',{cla:'".self::page."',checkbox:'listId[]'})\">导出</span>";
        }
        //返回
        return $this->homeFun($this->search($html,layout: 'pop',toolButton: $button));
    }

    /**
     * 字段初始化
     */
    public function fieldInit($fun): array
    {
        switch ($fun) {
            default:
                $tr = [
                    'team'      => [
                        'name'  => L('performance.table.team'),
                        'width' => 200,
                    ],
                    'aimType' => [
                        'name'  => L('performance.table.aimType'),
                        'width' => 150,
                    ],
                    'evaluation'  => [
                        'name'  => L('performance.table.evaluation'),
                        'width' => 300,
                    ],
                    'rule'         => [
                        'name'  => L('performance.table.rule'),
                        'width' => 300,
                    ],
                    'basis'          => [
                        'name'  => L('performance.table.basis'),
                        'width' => 200,
                    ],
                    'score'    => [
                        'name'  => L('performance.table.scroe'),
                        'width' => 150,
                        'sort' => 1,
                    ],
                    'time'    => [
                        'name'  => L('department.table.creatTime'),
                        'width' => 200,
                        'sort' => 1,
                    ],
                    'state'    => [
                        'name'  => L('trainingPlan.table.state'),
                        'width' => 100,
                    ]
                ];
        }
        return $tr;
    }

    /*客户列表-查询结果*/
    public function homeSearch()
    {
        //like查询数组
        $like = array();
        //全等查询数组
        $equal = array(
            "team" => $this->post('team'),//绩效组
        );
        $and = "";
        if ($this->post('createTime')) {
            $and .= self::timeComparison($this->post('createTime'));
        }
        //排序
        $orderBy = $this->listSort(array(
            "search"  => $this->post('list_sort_key') ?: 'time',
            "sort" => $this->post('list_sort') ?: "desc",
            "array"   => array(),
        ));
        //获取查询结果
        $where = search(array("like" => $like, "=" => $equal)) . $and;
        $page = $this->page(array("table" => self::table, "where" => $where, "order" => $orderBy['orderBy']));
        $_SESSION[self::page]['sql'] = $page['fullSql'];
        //获取自定义字段参数
        $installSearch = $this->installSearch();
        $body          = [];
        //表格控件区
        $liButton = array(
            $this->checkAll("listForm", "listId")
        );
        //获取记录
        $url = root . "control/adIndex.html?cla=" . self::page;
        foreach ($page['array'] as $array) {
            //列表控件
            $dominate = array(
                "box" => array("name" => "listId", "value" => $array['id']),
                "detail" => array("title" => L('performance.table.aimInfo'), "click" => "newIframe('" . L('performance.table.aimInfo') . "','" . $url . "&fun=detail&id=" . $array['id'] . "')"),
            );
            $liButton[] = $this->dominate($dominate);
            //本行初始化
            $row = [];
            foreach ($installSearch['key'] as $key) {
                switch ($key) {
                    default:
                        $row[] = isset($array[$key]) && $array[$key] ? $array[$key] : '';
                }
            }
            $body[] = $row;
        }
        //控件
        $button = "";
        //生成页面
        $li = $this->li(array(
            "body" => $body,
            "install" => $installSearch,
            "button" => array("html" => $liButton,"width" => 120),
            "orderBySign" => $orderBy,
            "page" => $page['para'],
        ));
        //返回
        $json['html'] = $page['hint'] . $button . "<form name='listForm'>" . $li . "</form>" . $page['button'] . clear;
        return json_encode($json, 320);
    }

    /**
     * 导出
     */
    public function exportData()
    {
        $templateId = $this->get('templateId');
        $checkedId = $this->get('checkedId')?explode(',',$this->get('checkedId')):[];
        if (!$this->power(self::page, 'export')) {
            $_SESSION['warn'] = L('staffProfiles.tip.permission_export_warn');
        } else {
            $data = [];
            $title =[];
            $tempFieldAll = importTemplateClass::templateField(self::page, 'exportFieldInit', id:$templateId);
            foreach ($tempFieldAll as $array) {
                if ($array['display']){
                    $title[] = $array['aliasName'];
                }
            }
            if (!self::is_null_array($checkedId)){
                $result = find(array("table" => self::table, "where" => "id in ('".implode("','", $checkedId)."') order by time desc"))['array'];
            }else{
                $sql   = $_SESSION[self::page]['sql'];
                $result   = sqlFind($sql);
            }
            foreach ($result as $array){
                $column = [];
                foreach ($tempFieldAll as $templateField){
                    if ($templateField['display']){
                        $column[] = match ($templateField['columnName']){
                            '绩效组'=>$array['team'],
                            '目标类型'=>$array['aimType'],
                            '目标定义及评价要点'=>$array['evaluation'],
                            '评价扣分细则'=>$array['rule'],
                            '取数依据'=>$array['basis'],
                            '分值'=>$array['score'],
                            '备注'=>$array['text'],
                            '状态'=>$array['state'],
                            '创建日期'=>$array['time'],
                            default=>'',
                        };
                    }
                }
                $data[] = $column;
            }
            $text = str_replace(['{{staffName}}'], [$this->control['name']], L('performance.table.aimeDownload'));
            $this->logText(["type" => self::page, "text" => $text]);
            $this->excelOut($title, $data, L('performance.table.aim') . ".xlsx");
            exit(0);
        }
        header("Location:" . getenv("HTTP_REFERER"));
    }

    /**
     * 下载模板
     */
    public function downloadModel()
    {
        $templateId = $this->get('templateId');
        if (!$this->power(self::page, 'import')) {
            $_SESSION['warn'] = L('staffProfiles.tip.permission_import_warn');
        }  else {
            $exampleData[] = ['销售部门', '成交单', '月回款金额达到20万', '每差10万扣10分', '销售回款', '20', '样例数据，导入时请删除本条数据'];
            $excel    = $this->excelHead();
            $fileName = self::title.'导入模板-'.importTemplateClass::getName($templateId).'.xlsx';
            $filePath = $excel->fileName($fileName, 'sheet1');
            $format = new \Vtiful\Kernel\Format($filePath->getHandle());
            $templateField = importTemplateClass::templateField(self::page, 'importFieldInit', id:$templateId);
            $index         = 0;
            foreach ($templateField as $k => $array) {
                if ($array['display']){
                    $backgroundStyle=null;
                    if (importTemplateClass::getIsMustValue($this->importFieldInit(), $array['columnName'])){
                        //必填项判断
                        $backgroundStyle  = $format->background(
                            0xFFC04B
                        )->toResource();
                    }
                    $filePath->insertText(0, $index, $array['aliasName'],'',$backgroundStyle);
                    foreach ($exampleData as $y=>$example){
                        $exampleVal = match ($array['columnName']){
                            '绩效组'=>$example[0],
                            '目标类型'=>$example[1],
                            '目标定义及评价要点'=>$example[2],
                            '评价扣分细则'=>$example[3],
                            '取数依据'=>$example[4],
                            '分值'=>$example[5],
                            '备注'=>$example[6],
                            default=>'',
                        };
                        $filePath->insertText($y+1, $index, $exampleVal);
                    }
                    $index++;
                }
            }

            $text = str_replace(['{{staffName}}'], [$this->control['name']], L('performance.table.aimeDownload'));
            $this->logText(["type" => self::page, "text" => $text]);
            $this->excelOutPut($filePath,$fileName);
            exit(0);
        }
        header("Location:" . getenv("HTTP_REFERER"));
    }


    /*数据导入分析*/
    public function importData()
    {
        $templateId = $this->post('templateId');
        if (!$this->power(self::page, 'import')) {
            $json['warn'] = L('staffProfiles.tip.permission_import_warn');
        }  else {
             $fomatArray = [];//导入数据格式同一为TYPE_STRING
            foreach ($this->importFieldInit() as $value){
                $fomatArray[] = \Vtiful\Kernel\Excel::TYPE_STRING;
            }
            $data = $this->importHead(format: $fomatArray);
            $x = 0;
            $text = '';
            $headArray = [];
            $row_list=0;
            foreach ($data as $i => $row) {
                $row_list++;
                if ($i==0){
                    $templateField = importTemplateClass::templateField(self::page, 'importFieldInit', id:$templateId);
                    $headArray = importTemplateClass::combinHead($templateField,$row);
                }
                if ($i > 0) {
                    $rowData = formSubArray($row);
                    //只接收模板中选中的字段的值
                    $cell = [];
                    foreach ($headArray as $index=>$headName){
                        $cell[$headName] = $rowData[$index]??'';
                    }
                    //初始化未被模板需要的字段的值
                    foreach ($this->importFieldInit() as $value){
                        $cell[$value['columnName']] = $cell[$value['columnName']]??'';
                    }
                    $field = array(
                        "id" => self::getId(),
                        'stid' => $this->control['stid'],
                        "team" => $cell['绩效组'],
                        'aimType' => $cell['目标类型'],
                        "evaluation" => $cell['目标定义及评价要点'],
                        "rule" => $cell['评价扣分细则'],
                        "basis" => $cell['取数依据'],
                        'score' => $cell['分值'],
                        'text' => $cell['备注'],
                        'state' => '启用',
                        "updateTime" => $this->time,
                        "time" => $this->time,
                    );
                    $userNo = codeTemplateClass::generateCode(self::page, [
                        'prefix' => 'JXMB',
                        'table' => self::table,
                        'field' => 'orderNo',
                        'where' => '',
                    ], $field);
                    $field['orderNo'] = $userNo;
                    $annotation = [
                        'team' => L('performance.table.team'),
                        'evaluation' => L('performance.table.evaluation'),
                        'score' => L('performance.table.scroe'),
                    ];
                    $rules = [
                        'team' => 'required',
                        'evaluation' => 'required',
                        'score' => 'required|numeric',
                    ];
                    $line = str_replace(['{{i}}'], [$row_list], L('job.other.line'));
                    // 校验是否符合规则
                    $vt = new \verify();
                    $result = $vt->setAliases($annotation)->validate($field, $rules)->isOk();
                    if ($result === false) {
                        $text .= $line . "：" . $vt->getErrs()[0];
                    } else {
                        $warn = insert(["table" => self::table, "field" => $field]);
                        if (in_array($warn, ["新增成功", "更新成功"])) {
                            $x++;
                            $text .= $line . "：" . L('job.other.import_success') . "<br>";
                        } else {
                            $text .= $line . "：" . L('job.other.import_failed') . "<br>";
                        }
                    }
                }
            }

            $total = count($data)-1;
            $json['data'] = [
                'text'=>$text,
                'title'=>"您导入了{$total}条数据，成功{$x}条，失败".($total-$x)."条",
            ];
            $text = str_replace(['{{staffName}}', '{{fileName}}'], [$this->control['name'], $_FILES['file']['name']], L('job.other.import_log')) . '：' . $text;
            $this->logText(["type" => self::page, "text" => $text]);
            $json['warn'] = 2;
        }
        return json_encode($json,320);
    }


    /**
     * 编辑页
     * @return string
     */
    public function edit()
    {
        $id = $this->post('id');
        $info = query(self::table, " id = '" . $id . "' ");
        //表单
        $html = $this->layerEdit([
            "table" => [
                [
                    must . L('performance.table.team') . "：" => select(array('name' => 'team', 'title' => L('performance.table.team'), 'class' => 'select', 'value' => $info['team'], 'option' => explode('，', para('performanceTeam')))),
                    L('performance.table.aimType') . "：" => select(array('name' => 'aimType', 'title' => '目标类型', 'class' => 'select', 'value' => $info['aimType'], 'option' => explode('，', para('performanceAim')))),
                ],
                [
                    must . L('performance.table.evaluation') . "：" => text(array('name' => 'evaluation', 'class' => 'long', 'value' => $info['evaluation'])),
                ],
                [
                    L('performance.table.rule') . "：" => text(array('name' => 'rule', 'class' => 'long', 'value' => $info['rule'])),
                ],
                [
                    L('performance.table.basis') . "：" => text(array('name' => 'basis', 'class' => 'text', 'value' => $info['basis'])),
                    must . L('performance.table.scroe') . "：" => text(array('name' => 'score', 'class' => 'text', 'value' => $info['score'])) . componentClass::tipComponent(L('performance.table.cantmorethan')),
                ],
                [
                    L('performance.table.text') . "：" => textarea(array('name' => 'text', 'class' => 'textarea', 'value' => $info['text'])),
                ],
            ],
        ]);
        //返回
        return $this->layer(array("title" => L('job.button.editor').self::title, "height" => 350, "html" => $html));
    }


    public function editEdit()
    {
        $id = $this->post('id') ?: self::getId();
        $field = [
            'team' => $this->post('team'),
            'aimType' => $this->post('aimType'),
            'evaluation' => $this->post('evaluation'),
            'basis' => $this->post('basis'),
            'rule' => $this->post('rule'),
            'score' => $this->post('score'),
            'text' => $this->post('text'),
        ];
        $annotation = [
            'team' => L('performance.table.team'),
            'evaluation' => L('performance.table.evaluation'),
            'score' => L('performance.table.scroe'),
        ];
        $rules = [
            'team' => 'required',
            'evaluation' => 'required',
            'score' => 'required|numeric',
        ];
        // 校验是否符合规则
        $vt = new \verify();
        $result = $vt->setAliases($annotation)->validate($field, $rules)->isOk();
        if ($result === false) {
            $json['warn'] = $vt->getErrs()[0];  // 多个规则提示最前面一条
            goto resp;
        }
        //判断同一绩效组分值总和是否超过100
        $score = find(array('table' => self::table, 'sum' => "score", 'where' => " and team = '$field[team]' and id !='$id'"));
        //判断
        if (!$this->power(self::page, "edit")) {
            $json['warn'] = L('performance.table.aim_edit_permission');
        } elseif ($score + $field['score'] > 100) {
            $json['warn'] = L('performance.table.cantmorethan');
        } else {
            $where = " id = '$id' ";
            $info = query(self::table, $where);
            if (!$info['id']) {
                $userNo = codeTemplateClass::generateCode(self::page, [
                    'prefix' => 'JXMB',
                    'table' => self::table,
                    'field' => 'orderNo',
                    'where' => '',
                ], $field);
                $field = array_merge($field, [
                    'id' => $id,
                    'orderNo' => $userNo,
                    'state' => '启用',
                    'stid' => $this->control['stid'],
                    'time' => $this->time
                ]);
                $json['warn'] = static::insert(["table" => self::table, "field" => $field]);
            } else {
                $json['warn'] = static::update([
                    "table" => self::table,
                    "field" => $field,
                    "where" => $where
                ]);
            }
            if (in_array($json['warn'], ["新增成功", "更新成功"])) {
                //添加日志
                $text = str_replace(['{{staffName}}', '{{name}}', '{{id}}'], [$this->control['name'], $field['team'], $id], L('performance.table.aim_edit_text'));
                $this->logText(["type" => self::page, "text" => $text]);
                //返回
                $_SESSION['warn'] = $json['warn'];
                $json['warn'] = 2;
                $json['href'] = root . "control/adIndex.html?cla=" . $this->get('cla') . "&fun=detail&id=" . $id;
            }
        }

        resp:
        return json_encode($json, 320);
    }

    /*详情页*/
    public function detail(): string
    {
        $info = query(self::table, " id = '{$this->get('id')}'");
        if (empty($info['id'])) {
            $html = L('performance.table.aimInfo');
        } else {
            //菜单
            $data = array(
                "id" => $info['id'],
            );
            $button = [];
            if ($this->power(self::page, "edit")) {
                //按钮
                $button[] = [
                    "name" => L('department.button.delete'),
                    "type" => "弹出层",
                    "cla" => $this->get('cla'),
                    "fun" => "operate",
                    "post" => ["act" => 'del', "id" => $info['id']],
                ];
                //按钮
                $button[] = [
                    "name" => '编辑',
                    "type" => "弹出层",
                    "cla" => $this->get('cla'),
                    "fun" => "edit",
                    "post" => ["id" => $info['id']],
                    'style' => 'li-btn-blue-bg',
                ];
            }

            //生成表单
            $data['button'] = $this->tableShowButton($button);
            $data['html'] = $this->tableShow(array(
                "详细信息" => array(
                    array(
                        L('performance.table.team') => $info['team'],
                        L('performance.table.aimType') => $info['aimType'],
                        L('performance.table.evaluation') => $info['evaluation'],
                        L('performance.table.rule') => $info['rule'],
                    ),
                    array(
                        L('performance.table.basis') => $info['basis'],
                        L('performance.table.scroe') => $info['score'],
                    ),
                    array(
                        L('trainingPlan.table.text') => pre($info['text']),
                    ),
                ),
                L('staffProfiles.detail.system_info') => array(
                    array(
                        L('performance.table.aimOrderNo') => $info['orderNo'],
                        L('department.table.creator') => self::findStaff($info['stid']),
                        L('department.table.creatTime') => $info['time'],
                        L('department.table.updateTime') => $info['updateTime'],
                    ),
                ),
            ));
            //生成页面
            $html = $this->tab($data);
        }
        //返回
        return $html;
    }

    /**
     * 启用/停用
     */
    public function stateSwitch()
    {
        $type = $this->post('type');
        $typeText = match ($type) {
            '启用' => L('topic.table.enable'),
            default => L('topic.table.unenable'),
        };
        //生成表单
        $html = $this->layerEdit(array("table" => array(
            array(
                L('topic.table.tip') . "：" => L('topic.table.changeTip') . "：" . $typeText,
            ),
        ), 'hidden' => hidden(array('name' => 'type', 'value' => $type))));
        //返回
        return $this->layer(array("title" => L('topic.table.stateChange'), "height" => 165, "html" => $html, 'formTwo' => 'listForm'));
    }

    /**
     * 启用/停用
     */
    public function stateSwitchEdit()
    {
        $idArr = $this->post('listId');
        $type = $this->post('type');
        if (!$this->power(self::page, "edit")) {
            $json['warn'] = L('performance.table.aim_edit_permission');
        } elseif (empty($idArr) || !is_array($idArr)) {
            $json['warn'] = L('job.model.no_data_warn');
        } elseif (!in_array($type, ['启用', '停用'])) {
            $json['warn'] = L('topic.table.type_error');
        } else {
            $json['warn'] = update(array('table' => self::table, 'field' => ['state' => $type], 'where' => " id in ('" . implode("','", $idArr) . "')"));
            if (in_array($json['warn'], ["新增成功", "更新成功"])) {
                //添加日志
                $operate = match ($type) {
                    '启用' => L('topic.table.enable'),
                    default => L('topic.table.unenable'),
                };
                $text = str_replace(['{{staffName}}', '{{state}}'], [$this->control['name'], $operate], L('performance.table.aim_enable_text')) . implode("','", $idArr);
                $this->logText(["type" => self::page, "text" => $text]);
                //返回
                $_SESSION['warn'] = $json['warn'];
                $json['warn'] = 2;
            }
        }
        //返回
        return json_encode($json, 320);
    }

    // 操作中转
    public function operate()
    {
        $act = $this->post('act') ?? '';
        $pwd = false; // 需要密码
        switch ($act) {
            default:
                $act = 'del';
                $msg = L('performance.table.aimOrderDel');
                $title = self::page . 'Delete';
                $function = 'delete';
                $form = self::page . 'OperateForm, listForm';
                $power = '';
                break;
        }
        if (!$this->power(self::page, $act)) {
            $_SESSION['warn'] = str_replace(['{{msg}}'], [$msg], L('jon.other.permission_warn'));
            $json = [
                'warn' => 2,
                'href' => root . 'control/adIndex.html?cla=' . $this->get('cla') . '&fun=home',
            ];
        } else {
            return $this->confirm([
                'title' => $title,
                'function' => $function,
                'form' => $form,
                'power' => $power,
                'pwd' => $pwd,
            ]);
        }

        resp:
        return json_encode($json, 320);
    }


    /**
     * 删除
     * @return bool|string
     */
    public function delete()
    {
        $array = $this->post['listId'] ?? $this->post['id'];
        if (!$this->power(self::page, "del")) {
            $json['warn'] = L('staffProfiles.tip.permission_del_warn');
        } elseif (empty($array)) {
            $json['warn'] = L('staffProfiles.tip.no_data_choose');
        } else {
            $text = "";
            $x = 0;
            $array = is_array($array) ? $array : [$array];
            foreach ($array as $id) {
                $info = query(self::table, " id = '$id' ");
                if ($info['state'] != '停用') {
                    $warn = L('topic.table.del_warn');
                } else {
                    //最后删除基本参数
                    delete(array("table" => self::table, "where" => " id = '$id' "));
                    //返回
                    $warn = L('job.other.delete_success');
                    $x++;
                }
                $text .= str_replace(['{{name}}', '{{evaluation}}', '{{id}}'], [$info['team'], $info['evaluation'], $info['id']], L('performance.table.aim_del_text')) . $warn . "。<br>";
            }
            //添加日志
            $text = str_replace(['{{staffName}}'], [$this->control['name']], L('performance.table.aim_del_log')) . "<br>" . $text;
            $this->logText(array("type" => self::page, "text" => $text));
            $_SESSION['warn'] = str_replace(['{{x}}'], [$x], L('performance.table.aim_del_warn'));
            $json['warn'] = 2;
            $json['href'] = root . "control/adIndex.html?cla=" . $this->get('cla') . "&fun=home";
        }
        return json_encode($json, 320);
    }


    /**
     * 导入模板字段初始化
     * @return array[]
     */
    public function importFieldInit($classify=''): array
    {
        return match ($classify) {
            default=>  [
                [
                    'columnName'=>'绩效组',
                    'aliasName'=>'绩效组',
                    'isMust'=>true,
                ],
                [
                    'columnName'=>'目标类型',
                    'aliasName'=>'目标类型',
                    'isMust'=>false,
                ],
                [
                    'columnName'=>'目标定义及评价要点',
                    'aliasName'=>'目标定义及评价要点',
                    'isMust'=>true,
                ],
                [
                    'columnName'=>'评价扣分细则',
                    'aliasName'=>'评价扣分细则',
                    'isMust'=>false,
                ],
                [
                    'columnName'=>'取数依据',
                    'aliasName'=>'取数依据',
                    'isMust'=>false,
                ],
                [
                    'columnName'=>'分值',
                    'aliasName'=>'分值',
                    'isMust'=>true,
                ],
                [
                    'columnName'=>'备注',
                    'aliasName'=>'备注',
                    'isMust'=>false,
                ],
            ]
        };
    }

    /**
     * 导出模板字段初始化
     * @return array[]
     */
    public function exportFieldInit($classify=''): array
    {
        return match ($classify) {
            default=>  [
                [
                    'columnName'=>'绩效组',
                    'aliasName'=>'绩效组',
                ],
                [
                    'columnName'=>'目标类型',
                    'aliasName'=>'目标类型',
                ],
                [
                    'columnName'=>'目标定义及评价要点',
                    'aliasName'=>'目标定义及评价要点',
                ],
                [
                    'columnName'=>'评价扣分细则',
                    'aliasName'=>'评价扣分细则',
                ],
                [
                    'columnName'=>'取数依据',
                    'aliasName'=>'取数依据',
                ],
                [
                    'columnName'=>'分值',
                    'aliasName'=>'分值',
                ],
                [
                    'columnName'=>'备注',
                    'aliasName'=>'备注',
                ],
                [
                    'columnName'=>'状态',
                    'aliasName'=>'状态',
                ],
                [
                    'columnName'=>'创建日期',
                    'aliasName'=>'创建日期',
                ],
            ]
        };
    }
}
